<!--
 * @Author: hifishroom
 * @Date: 2021-08-26 10:52:35
 * @LastEditTime: 2021-08-26 12:48:43
 * @FilePath: \backstage\src\views\background\TreeViewDetail.vue
-->
<template>
  <router-view></router-view>
</template>
<script>
export default {
  name: "TreeViewDetail",
  data() {
    return {
      currentRoute: this.$route.path
    };
  },
  watch: {
    //监听路由，只要路由有变化(路径，参数等变化)都有执行下面的函数
    $route: {
      handler: function(val, oldVal) {
        this.currentRoute = val.name;
      },
      deep: true
    }
  }
};
</script>
<style scoped>
h3 {
  margin-top: 10px;
  font-weight: normal;
}
</style>
